@extends('default.layouts.adminLoginHF')
@section('title')管理中心登陆@endsection
@section('headcss')
    @parent
    <link rel="stylesheet" href="{{asset('/default/css/admin/login.css')}}">
@endsection

@section('content')
    {{--主体登录部分--}}
    <div class="content">
        <div class="regCon">
            <div class="logInfo">
                <div class="logBox">
                    {{--输出全部错误信息--}}
                    @if(count($errors)>0)
                        <div class="errors">
                            <ul>
                                @if(is_object($errors))
                                    @foreach($errors->all() as $error)
                                        <li><span>{{$error}}</span></li>
                                    @endforeach
                                @else
                                    <li><span>{{$error}}</span></li>
                                @endif
                            </ul>
                        </div>
                    @endif
                    <h2>系统登陆</h2>
                    <div class="form">
                        <form action="{{ url('admin/login') }}" name="loginForm" id="loginForm" method="post">
                            {{csrf_field()}}
                            <ul>
                                <li>
                                    <div class="lLeft">
                                        <span class="icon"><i class="fa fa-fw fa-user"></i></span>
                                        <input type="text" name="name" id="name" class="text" placeholder="请输入用户名" tip="请输入用户名"
                                               value="{{ old('name') }}"/>
                                    </div>
                                    <div class="errinfo"></div>
                                </li>
                                <li>
                                    <div class="lLeft">
                                        <span class="icon"><i class="fa fa-lock"></i></span>
                                        <input type="password" name="password" id="password" class="text" placeholder="请输入密码" tip="请输入密码"
                                               value="{{ old('password') }}"/>

                                    </div>
                                    <div class="errinfo"></div>
                                </li>
                                
                                 <li>
                                    <div class="lLeft" style="width: 200px;">
                                        <span class="icon"><i class="fa fa-check-square-o"></i></span>
                                        <input type="text" name="code" id="code"  class="text" placeholder="请输入验证码"  tip="请输入验证码"
                                               style="width: 149px;" value="{{ old('code') }}"/>
                                    </div>
                                    <span class="code"><img src="{{captcha_src()}}" alt="" onclick="this.src='{{captcha_src()}}' + Math.random()"></span>
                                    <div class="errinfo"></div>
                                </li>

                                <li style="margin-left:3px; margin-top: 5px;">
                                    <input type="checkbox" name="agree" id="agree" checked class="checkBox"  value="1" />
                                    <label class="labelText" for="agree">同意并遵守<a href="">《系统协议》</a></label>
                                    <div class="errinfo"></div>
                                </li>
                                <li style="margin-top: 5px;">
                                    <input type="submit" class="sub" value="立即登录"/>
                                </li>
                            </ul>
                        </form>
                    </div>
                </div>

            </div>
        </div>
    </div>
@endsection

@section('footerjs')
    <script>
        var codeUrl = "{{ url('common/ajax_code') }}";
        var _token = "{{csrf_token()}}";
    </script>
    @parent
    {{--JS信息--}}
    <script type="text/javascript" src="{{asset('/default/js/jquery/jquery.validate.extend.js')}}"></script>
    <script type="text/javascript" src="{{asset('/default/js/jquery/jquery.enplaceholder.js')}}"></script>
    <script type="text/javascript" src="{{asset('/default/js/admin/login.js')}}"></script>

@endsection